// 封装频道请求
import request from '../utils/request'

/**
 *
 * @param {object} params
 * @returns promise
 */
// 获取所有频道列表
export const pannelList = () => {
  return request({
    method: 'get',
    url: '/v1_0/channels'

  })
}
// 获取添加列表
export const getUserList = (obj) => {
  return request({
    method: 'PATCH',
    url: '/v1_0/user/channels',
    data: {
      channels: [obj]
    }

  })
}
// 删除数据
export const deletUserList = target => {
  return request({
    method: 'DELETE',
    url: '/v1_0/user/channels/' + target

  })
}
